/*
 * BasicTypes.h
 *
 *	Author: stravant
 *	Description:
 *		
 */

#ifndef BASICTYPES_H_
#define BASICTYPES_H_

typedef signed char         schar;
typedef signed char         int8;
typedef short               int16;
// TODO: Remove these type guards.  These are to avoid conflicts with
// obsolete/protypes.h in the Gecko SDK.
#ifndef _INT32
#define _INT32
typedef int                 int32;
#endif

// The NSPR system headers define 64-bit as |long| when possible.  In order to
// not have typedef mismatches, we do the same on LP64.
#if __LP64__
typedef long                int64;
#else
typedef long long           int64;
#endif

typedef unsigned char      uint8;
typedef unsigned short     uint16;
// TODO: Remove these type guards.  These are to avoid conflicts with
// obsolete/protypes.h in the Gecko SDK.
#ifndef _UINT32
#define _UINT32
typedef unsigned int       uint32;
#endif

// See the comment above about NSPR and 64-bit.
#if __LP64__
typedef unsigned long uint64;
#else
typedef unsigned long long uint64;
#endif

typedef signed int         char32;


//Ownership of a resource being passed to a method or constructor,
//should the method take ownership, or leave it with the source
enum Ownership {
	kOwnershipTake,
	kOwnershipLeave,
};

#endif /* BASICTYPES_H_ */
